using System;
using System.Collections.Generic;
using System.Text;

using ClearCanvas.Common;
using ClearCanvas.Desktop;

using ClearCanvas.Desktop.View.WinForms;

namespace WindowsPrintPlugin
{
    [ExtensionOf(typeof(WindowsPrintComponentViewExtensionPoint))]
    public class WindowsPrintComponentView : WinFormsView, IApplicationComponentView
    {

        private WindowsPrintComponent _component;
        private WindowsPrintControl _control;

        public void SetComponent(IApplicationComponent component)
        {
            _component = (WindowsPrintComponent)component;
        }

        public override object GuiElement
        {
            get
            {
                if (_control == null)
                {
                    _control = new WindowsPrintControl(_component);
                }
                return _control;
            }
        }

    }
}